home *** CD-ROM | disk | FTP | other *** search
- ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
- ;; ;;
- ;; EuLisp Module Copyright (C) University of Bath 1991 ;;
- ;; ;;
- ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-
- (defmodule mover
- (streams driver arith lists list-operators extras futures threads others) ()
-
- (deflocal x 40)
- (deflocal y 180)
-
- (deflocal dx 10)
- (deflocal dy 5)
-
- (defun movit ()
- (tilnil
- (setq x (+ x dx))
- (setq y (+ y dy))
- (if (or (= x 20) (= x 480)) (setq dx (- dx)) nil)
- (if (or (= y 20) (= y 480)) (setq dy (- dy)) nil)
- (move X-stream 0 x y)
- (move X-stream 1 (- 500 y) x)
- (move X-stream 2 (- 500 x) (- 500 y))
- (move X-stream 3 y (- 500 x))
- t))
-
- (read-pixmap X-stream "bulb.xbm")
-
- (manage X-stream 0)
- (manage X-stream 0)
- (manage X-stream 0)
- (manage X-stream 0)
-
- )
-